package com.sky.service;


import com.sky.dto.ShoppingCartDTO;
import com.sky.entity.ShoppingCart;
import org.apache.ibatis.annotations.Delete;

import java.util.List;

public interface ShoppingCartService {

        /**
         * 添加购物车
         * @param shoppingCartDTO
         */
        void addShoppingCart(ShoppingCartDTO shoppingCartDTO);

        /**
         * 查看购物车
         * @param userId
         * @return
         */
        List<ShoppingCart> showShoppingCart(Long userId);

        /**
         * 清空购物车
         * @param userId
         */
        void cleanShoppingCart(long userId);


        /**
         * 删除购物车中一个商品
         * @param shoppingCartDTO
         */
        void subShoppingCart(ShoppingCartDTO shoppingCartDTO);
}
